raar.agent.process.sensor
Class RADistanceSensor
java.lang.Object
raar.agent.process.RAProcess
raar.agent.process.sensor.RASensor
raar.agent.process.sensor.RARegionSensor
raar.agent.process.sensor.RARegionSensor_Pie
raar.agent.process.sensor.RADistanceSensor
- All Implemented Interfaces:
- java.io.Serializable
public class RADistanceSensor
- extends RARegionSensor_Pie
A sensor with a response to objects of a certain colour within a pie-piece-
shaped region. Returns the distance to the nearest object of a certain colour,
relative to the radius of the pie.
- See Also:
- Serialized Form
|
Method Summary |
java.lang.String |
explain()
Explain what the sensor does. |
java.awt.Color |
getColor()
Colour representation. |
void |
setColor(java.awt.Color c)
|
java.lang.String |
toString()
String representation. |
| Methods inherited from class raar.agent.process.sensor.RASensor |
acceptsInput, dumpRegisters, execute, get, getAgent, getDataType, getInputNames, getInputObjects, getOutputNames, getOutputObjects, getSensorValue, isSpecial, set, setAgent, setOutput, setSourceCode, suppliesOutput |
| Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
RADistanceSensor
public RADistanceSensor(RAAgent agent)
- Construct the sensor.
getColor
public java.awt.Color getColor()
- Description copied from class:
RASensor
- Colour representation.
- Overrides:
getColor in class RASensor
setColor
public void setColor(java.awt.Color c)
toString
public java.lang.String toString()
- String representation.
- Specified by:
toString in class RASensor
explain
public java.lang.String explain()
- Explain what the sensor does.
- Specified by:
explain in class RASensor